<!doctype html>
<html>
<head>
    <meta charset="UTF-8">
    <title>后台管理</title>
    <link rel="stylesheet" type="text/css" href="__PUBLIC__/Admin/css/common.css"/>
    <link rel="stylesheet" type="text/css" href="__PUBLIC__/Admin/css/main.css"/>
    <script type="text/javascript" src="__PUBLIC__/Admin/js/libs/modernizr.min.js"></script>
    <script language="javascript" type="text/javascript" src="__PUBLIC__/Admin/My97DatePicker/WdatePicker.js"></script>
    <script src="__PUBLIC__/Admin/js/libs/jquery.js"></script>
    <script src="__PUBLIC__/Admin/js/libs/list.js"></script>
</head>
<body>
{:W("Public/topShow")}
<div class="container clearfix">
    {:W("Public/sideShow")}
    <!--/sidebar-->
    <div class="main-wrap">
      
        <div class="crumb-wrap">
            <div class="crumb-list"><i class="icon-font"></i><a href="{:U('index/index')}">首页</a><span class="crumb-step">&gt;</span><a class="crumb-name" href="{:U('Article/index')}">文章管理</a><span class="crumb-step">&gt;</span><span>修改文章</span></div>
        </div>
        <div class="result-wrap">
            <div class="result-content">
                <form action="{:U('Article/doModArticle')}" method="post" id="myform" name="myform" enctype="multipart/form-data">
                    <table class="insert-tab" width="100%">
                        <tbody>
                            <tr>
                                <th><i class="require-red">*</i>文章所属分类：</th>
                                <td>
				  <select name="pid">
                                    <foreach name="category" item="categorys">
                                      <option value="{$categorys.id}" <if condition="$categorys['id'] == $pid">selected</if> >{$categorys.catname}</option>
                                      <if condition="$categorys['child']">
					<foreach name="categorys['child']" item = "child">
					  <option value="{$child.id}" <if condition="$child['id'] == $pid">selected</if> >&nbsp;&nbsp;&nbsp;|-{$child.catname}</option>
					</foreach>
                                      </if>
                                    </foreach>
                                  </select>
                                </td>
                            </tr>
                            <tr>
                                <th><i class="require-red">*</i>文章名称：</th>
                                <td>
                                    <input class="common-text required" value="{$article.title}" required id="title" name="title" size="50"  type="text">
                                </td>
                            </tr>
			    <tr>
                            <th><i class="require-red">*</i>文章图片：</th>
                            <td>
                            <input class="common-text required" id="title" name="image" size="50"  type="file">
                            </td>
                            </tr>
                	    <tr>
                              <th><i class="require-red">*</i>是否推荐：</th>
                              <td>
				<select name="flag">
				  <option value=""  <if condition="$article['flag'] == ''">selected</if>>不推荐</option>
				  <option value="c" <if condition="$article['flag'] == 'c'">selected</if>>推荐</option>
				</select>
                              </td>
                            </tr>
                            <tr>
                                <th><i class="require-red">*</i>文章内容：</th>
                                <td>
                                    <!-- 加载编辑器的容器 -->
                                    <script id="container" name="content" type="text/plain">
                                        {$article.content}
                                    </script>
                                    <!-- 配置文件 -->
                                    <script type="text/javascript" src="__PUBLIC__/Admin/utf8-php/ueditor.config.js"></script>
                                    <!-- 编辑器源码文件 -->
                                    <script type="text/javascript" src="__PUBLIC__/Admin/utf8-php/ueditor.all.js"></script>
                                    <!-- 实例化编辑器 -->
                                    <script type="text/javascript">
                                        var ue = UE.getEditor('container');
                                    </script>
                                </td>
                            </tr>
                            <tr>
                                <th></th>
                                <td>
                                    <input type="hidden" name='id' value="{$article.id}">
                                    <input class="btn btn-primary btn6 mr10" value="提交" type="submit">
                                    <input class="btn btn6" onclick="history.go(-1)" value="返回" type="button">
                                </td>
                            </tr>
                        </tbody></table>
                </form>
            </div>
        </div>

    </div>
    <!--/main-->
</div>
</body>
</html>
